<!DOCTYPE html>
<html lang="cn">
<head>
    <meta charset="UTF-8">
    <title>Document</title>
    <style type="text/css"></style>
</head>
<body>
    <h1>window</h1>
    <hr>

    <button onclick="window.open()">open</button>
    <button onclick="window.open('http://www.itxdl.cn')">ITXDL</button>
    <button onclick="window.open('http://www.itxdl.cn', 'yanyan')">ITXDL(本)</button>
    <button onclick="window.open('http://www.itxdl.cn', '')">ITXDL(本)</button>
    <button onclick="window.open('http://www.itxdl.cn', '', 'width=300,height=600')">指定打开的窗口大小</button>

    <button onclick="window.print()">开启打印</button>

    <script>
    window.name = 'yanyan';

    // console.log(window);
    var obj = {name:'艳艳'};
    console.log(obj);
    console.log(window.obj);

    var a = 100;
    console.log(window.a);

    function demo() {
        console.log('demo....');
    }
    window.demo();

    // alert()     警告框
    // var a = alert('FBI Warning: ');
    // console.log(a); // undefined
    
    // confirm()   确认框
    // var b = confirm('你确定吗?');
    // console.log(b);

    // prompt()    输入框
    // var c = prompt('请输入您的银行卡密码: ');
    // console.log(c);


    </script>
</body>
</html>